namespace Digitalmes.Events
{
    public class Deferral : IDisposable
    {
        private readonly Action completeTask;

        public Deferral(Action completeTask)
        {
            this.completeTask = completeTask;
        }

        public void Dispose()
        {
            completeTask();
        }
    }
}